package tec;
import javax.swing.JPanel;
import javax.swing.JFrame;
import java.awt.Component;
import java.awt.Toolkit;
public final class MesFenetres {
  private MesFenetres() {
  }

  static public JFrame creerUneFenetre(String titre, JPanel v) {
    JFrame fenetre = new JFrame(titre);

    fenetre.setSize(v.getPreferredSize().width,
                    v.getPreferredSize().height);
    fenetre.getContentPane().add(v);

    return fenetre;
  }
}

